package org.khd.base.query;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class BaseQuery {
    //    页码
    private Long currentPage = 1L;
    //    每页条数
    private Integer pageSize = 10;
    //关键字查询
    private String keywords;

    //JavaBean方式查询改变的页码
    public Long getStartIndex(){
        return (currentPage - 1)*pageSize;
    }
}
